package com.springcloud.tread.controller;

import com.springcloud.tread.pojo.IndexData;
import com.springcloud.tread.service.IndexDataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class IndexDataController {

    @Autowired
    IndexDataService indexDataService;

    /**
     * 操作指数数据
     */

    @GetMapping("/provider/getIndexData/{id}")
    public List<IndexData> getIndexData(@PathVariable String id){
        return  indexDataService.get(id);
    }

}
